<template>
  <div>
    <el-dialog v-bind="dialogProp" :before-close="handleClos" :close-on-click-modal="false"
               :destroy-on-close="true" v-dialogDrag>
      <div style="width:100%;height:2px;background:#009688;margin-bottom: 10px;"></div>
      <el-form :model="ruleForm" ref="ruleForm" label-width="120px" class="demo-ruleForm"
               size="small" :disabled="isDisabled">

        <el-row :gutter="16" justify="start">
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="单位:" prop="deptName">
              <el-input v-model="ruleForm.deptName" disabled></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="盘点单号:" prop="taskNo">
              <el-input v-model="ruleForm.taskNo" type="datetime" style="width:100%" clearable disabled
              >
              </el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="盘点对象:">
              <el-input v-model="ruleForm.warehouseName" clearable style="width: 100%" disabled>

              </el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="盘点日期:">
              <el-date-picker v-model="ruleForm.planStime" type="datetime" style="width:100%" clearable
                              disabled>
              </el-date-picker>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="盘点人:" prop="personName">
              <el-input v-model="ruleForm.personName" clearable disabled></el-input>
            </el-form-item>
          </el-col>

          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="盘点方式:" prop="stockMethodName">
              <el-input v-model="ruleForm.stockMethodName" clearable disabled></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="详情描述:" prop="detailedDescription">
              <el-input v-model="ruleForm.detailedDescription" clearable disabled></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="设备名称:" prop="sbmc">
              <el-input v-model="ruleForm.sbmc" clearable disabled></el-input>
            </el-form-item>
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="出厂编码:" prop="factoryNo">
              <el-input v-model="ruleForm.factoryNo" disabled clearable></el-input>
            </el-form-item>
            <!-- @click.native="clickSbbm" -->
          </el-col>
          <el-col :xs="24" :sm="24" :md="24" :lg="12" :xl="8">
            <el-form-item label="设备类型:" prop="sblxmc">
              <el-input v-model="ruleForm.sblxmc" clearable disabled></el-input>
            </el-form-item>
          </el-col>
        </el-row>
      </el-form>
    </el-dialog>
    <!-- <countequipForm ref="countequipForm"></countequipForm> -->
  </div>

</template>
<script>
import countequipForm from "./countequipForm.vue";

export default {
  components: {countequipForm},
  data() {
    return {
      ruleForm: [],
      dialogProp: {
        visible: false,
        title: "盘点详情",
        width: "70%",
        top: "5px",
      },

      size: "medium",


    };
  },
  methods: {
    showDialog(isEdit, row) {
      console.log(isEdit, row);
      if (isEdit) {
        this.initData(row);
      }

    },


    //编辑渲染
    initData(data) {

      this.ruleForm = data
      this.dialogProp.visible = true


    },
    handleClos() {
      this.dialogProp.visible = false;
    },
    //穿透
    clickSbbm() {
      this.$emit('handleAudit', this.ruleForm)
    },


  },
};
// 创建一个简单的超链接渲染

</script>
<style>
.el-dialog__footer {
  width: 100%;
  border-top: 1px solid #e8e8e8;
}
</style>
